1. Technical Field
This invention relates to a process for converting color bit map data to compressed monochrome data, and more particularly to convert color bit map data to resolution scaled monochrome data in Printer Control Language Method Two compressed data without explicit processing of all repeating source color data.
2. Background Art
Prior art processes for converting source color images to monochrome rasterized bit maps typically require examination of each pixel of the source bit map and conversion of the color information for each pixel to a gray scale value. After conversion, the correct dithering matrix is retrieved and scaled output pixels are generated. This is a slow, cumbersome process involving a large number of computations. This is especially so when converting visual color image data to high resolution raster bit maps, such as those utilized by laser printers having print engines capable of 300 or even 600 dots per inch. The rasterized bit map for monochrome image at 300 dots per inch resolution requires approximately a megabyte of raster memory for each letter-size page. At 600 dots per inch, 3.8 megabytes of memory are required. If the conversion process converts each individual source pixel, one at a time, and dithers each scaled group of output pixels resulting from each source pixel, processing 3.8 megabytes of rasterized bits of output image results in 30 million conversion computations and 30 million dithering operations which can take a considerable amount of time.
Laser printers typically include an on board or internal memory capable of receiving rasterized data bit map information from a host processor. This bit map is used to construct page intermediate strips of rasterized data. The page intermediate strips of rasterized data re delivered to the laser print engine which operates at a constant speed. If new rasterized data is not available at a rate that keeps up with the engine's operation, a print "overrun" occurs and the page is not printable. To prevent this from occurring, page intermediate formatting must occur at a high enough rate to keep up with the print engine. This can only be accomplished if the host processor is sending formatted data at a high enough rate of speed, or the printer contains sufficient internal memory to hold the entire destination image bit map which has been delivered to it at perhaps a slower rate of speed from the host processor.
To maintain the cost of laser printers at a low level, substantial efforts have been directed to reducing the amount of required, on board, raster memory, such that it is not possible to hold a complete rasterized bit map of an image. In such cases, if the conversion, dithering and rasterization execution time, either in the random access memory (RAM) of the printer, or the host processor, is greater than the time within which page intermediate strips must be constructed for delivery to the print engine, print overruns will occur.
Execution time for prior art conversion procedures is oftentimes too slow to keep up with the construction times needed for the construction of page intermediate strips for delivery to the print engine. As a result, a number of data conversion and compression techniques are employed, usually executed in the host processor, prior to transmission of data to the printer memory to increase the rate of data transfer from the host processor to the on board memory, such that page intermediate construction can commence during the transfer while at the same time minimizing the amount of required internal printer RAM for raster memory. One of the most common compression methods is known as Printer Control Language (PCL) Method Two compression. PCL is a trademark of the assignee of this Application, Hewlett-Packard Co. PCL Method Two compression compares each byte of data to be sent, testing for whether it is "same" or "different" from a referenced byte read. If it is "same", Method Two continues to read ahead in a rasterized row of data until the test indicates either "end of line" or "different". From this information is constructed a two byte PCL compressed run, wherein the first byte indicates the number of times that the second byte is to be repeated in the rasterized row. In the event that the next byte read tests different from the previous byte read, then a literal run data string is constructed, wherein the first byte of the literal run indicates that the following bytes are to be printed in proper sequence. Method Two compression is an effective compression technique which is particularly useful for images which include numerous strings of repeated data.
Thus, in the prior art, conversion of the source color image to a rasterized bit map monochrome image has usually been completed and stored in the host processor RAM, and the compression procedure conducted prior to transmission of the bit map image data to the on-board RAM of the printer.
What is needed is a process which speeds up the conversion process by eliminating the need to convert each individual pixel's color data information to a gray scale value where there are strings of repeating color data. Also, to increase the speed of execution time, what is needed is a process by which the requirement to dither the scaled output pixels derived from the conversion of repeating source pixels is eliminated, particularly when upscaling to a higher resolution image than the original source image.
Accordingly, it is an object of this invention to provide a process by which strings of repeating source pixels need not all be converted to gray scale values, and wherein all of the scaled output pixels resulting from the scaling of the source pixels need not all be individually dithered to produce a complete rasterized bit map.
It is another object of this invention to provide a process by which the source image data can be converted directly into Printer Control Language Method Two compressed data, thus eliminating the need for processing the source image into a complete monochrome rasterized bit map prior to compression.